# s="hello itcast"
# count=0
# for e in s:
#     count+=1
# print(count)

s1="21381923sdasdfasdAAJLBVdhbbmdsanbds##%^^!@$"
count1=0
count2=0
count3=0
count4=0

for e in s1:
    if "0" <= e <= "9":
        count1+=1
    elif "a" <= e <= "z":
        count2 += 1
    elif "A" <= e <= "Z":
        count3 += 1
    else:
        count4+=1
print(count1,count2,count3,count4)
